-- background: 2745 from stack: in._ball_s_game -- bmap block id: 3127 -- flags: 0000 -- background id: 0 -- name: ----- HyperTalk script ----- on idle move 0,5 check end idle on arrowkey dir put the loc of bg btn "mr. ball" into oldloc if dir is "left" then move -20,0 if dir is "up" then move 0,-20 if dir is "right" then move 20,0 if dir is "down" then move 0,20 check if the loc of bg btn "Mr. Ball" is not within "0,0,512,342" then play "boing" set the loc of bg btn "mr. ball" to oldloc end if end arrowkey on move h,v set the loc of bg btn "mr. ball" to item 1 of the loc of bg btn "mr. ball"+h,item 2 of the loc of bg btn "mr. ball"+v end move on check repeat with i = 1 to the number of cd btns if the loc of bg btn "mr. ball" is within the rect of cd btn i then special i if the result is true then exit check coin i if the result is true then exit check bump exit check end if end repeat if the loc of bg btn "mr. ball" is within the rect of bg btn "next" then set the loc of bg btn "mr. ball" to the loc of bg btn "next" lock screen go to next card show bg btn "mr. ball" at 256,20 play "Harpsichord" unlock screen with visual scroll up end if end check on opencard repeat with i = 1 to the number of cd btns show cd btn i end repeat put "World"&&the number of this card into bg fld "status" updateguys end opencard on special i if the short name of cd btn i is "special" then send stuff to cd btn i return true end if end special on updateguys global guys,coins if guys is empty then exit updateguys put empty into bg fld "guys" repeat with i = 1 to guys put "• " after bg fld "guys" end repeat put coins into bg fld "coins" end updateguys on bump global guys play "boing" if guys is 0 then go to card "Lost" else subtract 1 from guys updateguys set the loc of bg btn "mr. ball" to 256,20 end if end bump on coin i global coins if the short name of cd btn i is "coin" then if the visible of cd btn i is false then exit to hypercard add 1 to coins put coins into bg fld "coins" hide cd btn i return true end if end coin -- part 1 (button) -- low flags: 00 -- high flags: 0000 -- rect: left=237 top=73 right=107 bottom=276 -- title width / last selected line: 0 -- icon id / first selected line: 1234 / 1234 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: Mr. Ball -- part 2 (button) -- low flags: 00 -- high flags: 8002 -- rect: left=0 top=271 right=319 bottom=512 -- title width / last selected line: 0 -- icon id / first selected line: 18602 / 18602 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: Next -- part 3 (field) -- low flags: 01 -- high flags: 0001 -- rect: left=0 top=319 right=342 bottom=79 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 152 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: Status -- part 4 (button) -- low flags: 00 -- high flags: 8001 -- rect: left=468 top=320 right=342 bottom=512 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 1 -- font id: 0 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: Start ----- HyperTalk script ----- on mouseUp global guys,coins put 0 into coins put 3 into guys go to first card updateguys set the loc of bg btn "mr. ball" to 256,20 end mouseUp -- part 5 (field) -- low flags: 01 -- high flags: 0001 -- rect: left=119 top=319 right=342 bottom=265 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 152 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: Guys -- part 6 (field) -- low flags: 01 -- high flags: 0001 -- rect: left=371 top=323 right=340 bottom=408 -- title width / last selected line: 0 -- icon id / first selected line: 0 / 0 -- text alignment: 0 -- font id: 21 -- text size: 12 -- style flags: 0 -- line height: 16 -- part name: coins